// const fn = (num: number): void => {
//   console.log(num)
//   return 'xx' // 报警告
// }

type Person = {
  name: string;
  sayHi(info: string): void; // void 不报警告
  code(code: string): string;
};

let person1: Person = {
  name: 'jack',
  sayHi(info) {
    console.log(info);
    return 'info'; // 不报警告
  },
  code(code) {
    return code;
  },
};
